Skip to content

fix: wait before compress and normalize pidstat CPU values - #61

Merged
k-rister merged 2 commits into
masterfrom
fix-sysstat-bugs
Jul 9, 2026
Merged

fix: wait before compress and normalize pidstat CPU values#61
k-rister merged 2 commits into
masterfrom
fix-sysstat-bugs

Conversation

@k-rister

@k-rister k-rister commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add wait after killing collector processes before xz compression to prevent corrupting the last sample
  • Fix "sysstst" → "sysstat" typo in error message, add -r flag to while read, quote filename variable
  • Normalize pidstat CPU values from 0-100 to 0-1 range to match mpstat's convention for the same Busy-CPU/NonBusy-CPU metric types

Test plan

  • crucible run with sysstat tool completes — verify compressed output is not truncated
  • pidstat metrics in CDM show values in 0-1 range consistent with mpstat

Resolves #60

🤖 Generated with Claude Code

k-rister and others added 2 commits July 8, 2026 16:33
Add wait after killing collector processes so they finish flushing data
to disk before xz compression starts. Without the wait, the last sample
could be corrupted or truncated. Also fix "sysstst" typo in error
message, add -r flag to while read, and quote the filename variable.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
pidstat reports CPU percentages in 0-100 range but mpstat normalizes
to 0-1 for the same Busy-CPU/NonBusy-CPU metric types. Divide by 100
to match mpstat's convention.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@k-rister k-rister self-assigned this Jul 8, 2026
@k-rister
k-rister requested a review from a team July 8, 2026 21:33
@project-crucible-tracking project-crucible-tracking Bot moved this to In Progress in Crucible Tracking Jul 8, 2026

@atheurer atheurer left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The pidstat /100 normalization is important — CPU values were 100x inflated in CDM. Wait-before-compress and the typo fix are good too.

@k-rister
k-rister merged commit 8aced49 into master Jul 9, 2026
72 of 74 checks passed
@github-project-automation github-project-automation Bot moved this from In Progress to Done in Crucible Tracking Jul 9, 2026
@k-rister
k-rister deleted the fix-sysstat-bugs branch July 9, 2026 12:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

fix: no wait after kill before compression and pidstat metric normalization

2 participants